<?php


namespace app\common\model;


class Archives extends BaseModel
{
    protected $dateFormat = "Y-m-d";
    protected $append = ['content_url'];
    public function __construct(array $data = [])
    {
        parent::__construct($data);
    }

    public function getContentUrlAttr($value,$data)
    {
        return str_replace("/uploads/",request()->domain()."/uploads/",$data['content']);
    }

}